﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ApplicationEditPre.ascx.cs" Inherits="CentralOffice.WebClient.Tasks.ApplicationEditPre" %>

<table class="TableBlock" width="90%" align="center">
    <tr><td nowrap class="TableData" style="width: 113px">申请类别：</td><td nowrap class="TableData"><asp:DropDownList ID="ddlCategory" runat="server" AutoPostBack="true"  onselectedindexchanged="ddlCategory_SelectedIndexChanged"></asp:DropDownList></td></tr>
    <tr>
        <td nowrap class="TableData" style="width: 113px">采用的审批流程：</td>
        <td nowrap class="TableData">
            <asp:UpdatePanel ID="UpdatePanel3" runat="server" UpdateMode="Conditional" RenderMode="Inline">
                <ContentTemplate>
                    <asp:DropDownList ID="ddlProcess" runat="server" onselectedindexchanged="ddlProcess_SelectedIndexChanged" AutoPostBack="true"></asp:DropDownList>
                    
                </ContentTemplate>
                <Triggers><asp:AsyncPostBackTrigger ControlID="ddlCategory" /></Triggers>
            </asp:UpdatePanel>
            &nbsp;&nbsp;&nbsp;&nbsp;执行人：&nbsp;&nbsp;
<asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional" RenderMode="Inline">
                <ContentTemplate>
                    <asp:Literal ID="txtExecutor" runat="server"></asp:Literal>
                </ContentTemplate>
                <Triggers><asp:AsyncPostBackTrigger ControlID="ddlCategory" /><asp:AsyncPostBackTrigger ControlID="ddlProcess" /></Triggers>
            </asp:UpdatePanel>
        </td>
    </tr>
    <tr><td nowrap class="TableData" style="width: 113px">申请编号：</td><td nowrap class="TableData"><asp:TextBox ID="txtApplicationCode" runat="server" CssClass="BigInput" style="width:82%"></asp:TextBox><asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ErrorMessage="格式不正确" ValidationExpression="^\d{8}-\d{3}$" ControlToValidate="txtApplicationCode">(格式错误)</asp:RegularExpressionValidator></td></tr>
    <tr><td nowrap class="TableData" style="width: 113px">申请名称：</td><td nowrap class="TableData"><asp:TextBox ID="txtName" runat="server" CssClass="BigInput" style="width:82%"></asp:TextBox><span class="warning">（请先填写名称）</span><asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="任务名称必须填写" ControlToValidate="txtName">*</asp:RequiredFieldValidator></td></tr>
    <tr><td nowrap class="TableData" style="width: 113px">申请人：</td><td nowrap class="TableData"><asp:Literal ID="lblApplicant" EnableViewState="false" runat="server"></asp:Literal></td></tr>
    <tr><td nowrap class="TableData" style="width: 113px">审批内容：</td><td nowrap class="TableData"><asp:TextBox ID="txtContentText" runat="server" TextMode="MultiLine" Columns="120" Rows="10"></asp:TextBox></td></tr>
    <tr><td class="TableData">附件：</td><td class="TableData"><asp:FileUpload ID="fileAttachments" runat="server" Width="78%" /><asp:Literal ID="lblAttachments" EnableViewState="false" runat="server"></asp:Literal></td></tr>
    <tr><td nowrap class="TableControl" colspan="2" align="center"><asp:Button ID="btnSave" runat="server" Text="确定" CssClass="BigButton"  OnClick="btnSave_Click" /></td></tr>
</table>


<div style="margin-top:20px; margin-left:8px;"><h3>选定流程的审批步骤：</h3></div>
<div style="text-align:center">

<asp:UpdatePanel UpdateMode="Conditional" ID="upStep" runat="server" ChildrenAsTriggers="false">
<ContentTemplate>
<huag:OAGridView  id="gvStep" runat="server" DataKeyNames="Id" AllowSorting="True"  EnableExport="false" ConfirmDelete="true" skinid="DefaultGridView" Width="100%"  EnableViewState="false" >
   <Columns>
       <asp:BoundField DataField="StepOrder" HeaderText="步骤序号" SortExpression="StepOrder" />
       <asp:BoundField DataField="Name" HeaderText="步骤名称" SortExpression="Name"/>
       <asp:BoundField DataField="ApprovalProcess" HeaderText="所属审批流程" SortExpression="ApprovalProcess" />
       <asp:BoundField DataField="ApprovalByEmp" HeaderText="审批者" SortExpression="ApprovalByEmp" />
       <asp:BoundField DataField="ApprovalBy" HeaderText="审批角色" SortExpression="ApprovalBy" />
       <asp:BoundField DataField="ApprovalContent" HeaderText="要审批的内容" SortExpression="ApprovalContent" />
   </Columns>
</huag:OAGridView>
</ContentTemplate>
 <Triggers><asp:AsyncPostBackTrigger ControlID="ddlCategory" /><asp:AsyncPostBackTrigger ControlID="ddlProcess" /></Triggers>
</asp:UpdatePanel>

</div>

<asp:Literal ID="lblJavaScript" EnableViewState="false" runat="server"></asp:Literal>